/**
 * 描述：...
 * 作者：彭涛涛
 * 日期：2019/6/24
 * 版本：0.0.1
 **/

(function(E, KIT, RES) {
  var _buildTitle = function(title) {
    return E.view({cssClass: "r-p-l r-p-tb-sm r-bold r-bg-0-2 " + KIT.BD_COLOR}, title);
  };

  rapid.Page.create("LifecycExample", {
    render: {
      titleBar: "生命周期实例管理",
      other: E.block(
        E.window("wndExampleMenu",
          E.dataview("frmExampleMenu")
        )
      ),
      main: E.flex({cssClass: "r-full-h r-border-box r-p"},
        // 左侧
        E.view({cssClass: "r-full-h r-m-r-sm", cssStyle: "width:25em"},
          E.flexv({cssClass: "r-full-h"},
            _buildTitle("生命周期实例").addClass("r-bd-trl"),
            E.div(E.textbox({id: "txtSearch", mode: "search", tip: "实例名称...", cssClass: "r-col-6"})),
            E.flexitem({cssClass: "r-overflow-hide"},
              E.grid("grdLifecycExample")
            )
          )
        ),
        // 右侧
        E.flexitem({cssClass: "r-overflow-hide"},
          E.flexv({cssClass: "r-full-h"},
            _buildTitle("生命周期实例节点").addClass("r-bd-trl"),
            E.flexitem({cssClass: "r-overflow-hide"},
              E.grid("grdExampleNode")
            ),
            E.flexitem({cssClass: "r-overflow-hide"},
              E.flex({cssClass: "r-full-h"},
                E.flexitem({cssClass: "r-overflow-hide r-m-r-sm"},
                  E.flexv({cssClass: "r-full-h"},
                    _buildTitle("生命周期节点附件").addClass("r-bd-rl"),
                    E.flexitem({cssClass: "r-overflow-hide"},
                      E.grid("grdExampleNodeACC")
                    )
                  )
                ),
                E.flexitem({cssClass: "r-overflow-hide"},
                  E.flexv({cssClass: "r-full-h"},
                    _buildTitle("生命周期实例节点参与人员").addClass("r-bd-rl"),
                    E.flexitem({cssClass: "r-overflow-hide"},
                      E.grid("grdExampleNodePER")
                    )
                  )
                )
              )
            )
          )
        )
      )
    }
  });

})(rapid.html.Element, rapid.kit, rapid.res);